package com.pug.service.user;

import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.pug.mapper.user.UserMapper;
import com.pug.pojo.KssUser;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Service;

/**
 * Description:
 * Author: taimi 37310
 * Version: 1.0
 * Create Date Time: 2022/4/5 3:45.
 * Update Date Time:
 *
 * @see
 */
@Service
@Slf4j
public class UserServiceImpl extends ServiceImpl<UserMapper, KssUser> implements IUserService {
    @Override
    public KssUser getByPhone(String inputPhone) {
        LambdaQueryWrapper<KssUser> lambdaQueryWrapper = new LambdaQueryWrapper<>();
        lambdaQueryWrapper.eq(KssUser::getPhone,inputPhone);
        return this.getOne(lambdaQueryWrapper);
    }
}
